.pragma library

var currentClubType="";//论坛类型id
var currentBrandId="";//品牌的id
var currentForumId="";//论坛id
var currentForumPageNum="";//论坛的页数
var currentTopicId="";//帖子的Id
var currentTopicPageNum="";//帖子的页数

function setCurrentClubType(clubType) {
    currentClubType = clubType;
}
function getCurrentClubType(){
    return currentClubType;
}
function getCurrentBrandId(brandId){
    return currentBrandId;
}
function setCurrentBrandId(brandId){
    currentBrandId = brandId;
}

function setCurrentForumId(furumId){
    currentForumId = furumId;
}
function getCurrentForumId(){
    return currentForumId;
}

function setCurrentForumPageNum(num){
    currentForumPageNum=num;
}
function getCurrentForumPageNum(){
    return currentForumPageNum;
}
function setCurrentTopicId(id){
    currentTopicId=id;
}
function getCurrentTopicId(){
    return currentTopicId;
}
function setCurrentTopicPageNum(num){
    currentTopicPageNum =num;
}
function getCurrentTopicPageNum(){
    return currentTopicPageNum;
}

//获取论坛帖子具体url 的url
function getClubReplyLink(id){
    return "http://sp.autohome.com.cn/Nokia/ClubReplyLink.ashx?type=1&Id="+id+"&ShowOwner=&Page=1&count=20";
}
//获取论坛的url
function getForumUrl(id,clubType,index){
    return  "http://sp.autohome.com.cn/Nokia/ClubTopicList.ashx?type=1&Id="+id+"&ClubType="+clubType+"&Sort=&UpTopic=&Page="+index+"&count=20"
}
//获取论坛帖子的内容页面
function getClubPageUrl(clubId,index){
    return "http://sp.autohome.com.cn/clubreply.aspx?topicid="+clubId+"&page="+index;
}

function getTopicTypeColor(type){
     if("图"===type){
         return "#4965d6";
     }else if(type=="精"){
         return "#a60000";
     }else if(type=="荐"){
         return "#f16d95";
     }else{
         return "#ffde40";
     }
}


